//
//  AccountTransferRequest.swift
//  Exchange
//
//  Created by 孟祥群 on 2018/6/22.
//  Copyright © 2018年 common. All rights reserved.
//

import UIKit

class AccountTransferRequest: BaseRequest {
    var sendCoin:CoinAccountType = .legalType //发送币种
    var receiveCoin:CoinAccountType = .coinType//接收币种
    override func path() -> String {
        if sendCoin == .legalType {
            if receiveCoin == .coinType {
                return Api.Mine.legalOut
            }else {
                return Api.Mine.legaltoLever
            }
            
        }else if sendCoin == .coinType {
            if receiveCoin == .legalType {
                return Api.Mine.legalIn
            }else {
                return Api.Mine.leverIn
            }
            
        }else {
            if receiveCoin == .legalType {
                return Api.Mine.leverToLegal
            }else {
                return Api.Mine.leverOut
            }
        }
      
    }
    override func method() -> HTTPMethodType {
        return .post
    }
    override func openIndicator() -> Bool {
        return true
    }
}
